﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;


namespace TCM
{
    using System;
    using System.Collections.Generic;
    using System.ComponentModel;
    using System.ComponentModel.DataAnnotations;
    using System.ComponentModel.DataAnnotations.Schema; 
    public partial class COURSEBASE
    {
        [Display(Name="From Date")]
        [DataType(DataType.Text)]
        
        
        public string ExFromDate
        {
            get
            {
                if (this.STARTDATE.HasValue)
                    return this.STARTDATE.Value.ToString("dddd, MMMM d, yyyy");
                return string.Empty;
            }
            set
            {
                DateTime dt = Convert.ToDateTime(value);

                this.STARTDATE = dt.Date;

            }
        }

        [Display(Name = "To Date")]
        [DataType(DataType.Text)]
        
        
        public string ExToDate
        {
            get
            {
                if (this.ENDDATE.HasValue)
                    return this.ENDDATE.Value.ToString("dddd, MMMM d, yyyy");
                return string.Empty;
            }
            set
            {

                DateTime dt = Convert.ToDateTime(value);
                this.ENDDATE = dt.Date;
            }
        }
    }
}